<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ page import="com.pms.entity.Project" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
  <head>
    <title>项目管理系统-主页</title>
    <link rel="stylesheet" type="text/css" href="css/bootstrap.min.css" />
	<script type="text/javascript" src="js/jquery.js"></script>
	<script type="text/javascript" src="js/bootstrap.min.js"></script>
	<script type="text/javascript">
		$('.dropdown-toggle').dropdown();
	</script>
	<style type="text/css">
		.navbar{
			width:980px;
			margin:0 auto;
		}
	</style>
  </head>
  
  <body>
    <%@ include file="include/head.jsp" %>
    <div class="container">
    	<div class="page-header">
  			<h2>项目列表</h2>
  			<a href="newProject.jsp" class="btn btn-success btn-large"><i class="icon-plus icon-white"></i> 添加新项目</a>
  		</div>
  		<table class="table table-striped">
			 <thead>
			     <tr>
			         <th width="5%">#</th>
			         <th width="35%">项目名称</th>
			         <th width="60%">描述</th>
			     </tr>     
			 </thead>
			 <tbody>
			 <%
			 	List<Project> list=(List<Project>)request.getAttribute("projectlist");
			 	for(int i=0;i<list.size();i++){
			        		Project project=list.get(i);
			  %>
			     <tr>
			         <td><%=i+1 %></td>
			         <td>
			         	<a href="project.jspx?id=<%=project.getId()%>"><%=project.getName() %></a>
			         </td>
			         <td>
			         	<textarea rows="3" id="textarea" class="input-xlarge"><%=project.getDesc()%></textarea>
			         </td>
			     </tr>
			  	<%} %> 
			 </tbody>    
		</table>
    </div>
   
  </body>
</html>
